﻿@import "apptheme.less";

body {
    position: relative;
    background-color: #DDD;
}

#contenthost {
    height: 100%;
    width: 100%;
}

.fragment {
    /* Define a grid with rows for a banner and a body */
    -ms-grid-columns: 1fr;
    -ms-grid-rows: 128px 1fr;
    display: -ms-grid;
    height: 100%;
    width: 100%;
}

.fragment.fullpage {
    display: block;
}

.fragment header[role=banner] {
    /* Define a grid with columns for the back button and page title. */
    -ms-grid-columns: 39px 81px 1fr auto;
    -ms-grid-rows: 1fr;
    display: -ms-grid;

    .win-backbutton {
        -ms-grid-column: 2;
        margin-top: 59px;
    }

    .codelink {
        -ms-grid-column: 4;
        margin-top: 37px;
        margin-right: 40px;
        font-size: 20pt;
        opacity: 0;
        transition: all 200ms ease-in;

        &.visible {
            opacity: 1;
        }
    }

    .titlearea {
        -ms-grid-column: 3;
        margin-top: 37px;

        .pagetitle {
            width: calc(100% - 20px);

            .small {
                font-size: 0.4em;
                color: #AAA;
                margin-top: 8px;
            }
        }
    }
}

.fragment section[role=main] {
    -ms-grid-row: 2;
    height: 100%;
    width: 100%;
}

.mcn-splashcreen {
    background-color: @baseColor;
}

.split {
    display: -ms-grid;
    -ms-grid-rows: auto;
    -ms-grid-columns: 1fr 1fr;

    div:nth-child(2) {
        -ms-grid-column: 2;
    }
}

.desc-screen {
    display: -ms-grid;
    -ms-grid-rows: 5px 1fr 40px;
    -ms-grid-columns: 40px 300px 40px 1fr 40px;
    font-size: 14pt;

    .bloc-description {
        -ms-grid-row: 2;
        -ms-grid-column: 2;
        width: 100%;
        height: 100%;
        padding: 20px;
        border: 4px solid @baseColor;
        border-top-right-radius: 25px;
        border-bottom-left-radius: 25px;
        background-color: white;
        box-sizing: border-box;

        p {
            margin-top: 0.2em;
            margin-bottom: 0.2em;
            line-height: 1.2em;
        }
    }

    .bloc-content {
        -ms-grid-row: 2;
        -ms-grid-column: 4;
    }
}


#codeviewFlyout.childNavigator .childNavigator-contentPlaceholder {
    max-width: 900px;
}

@media screen and (orientation: landscape) and (min-width: 1300px) {
    #codeviewFlyout.childNavigator .childNavigator-contentPlaceholder {
        max-width: 1100px;
    }
}

@media screen and (orientation: landscape) and (min-width: 1900px) {
    #codeviewFlyout.childNavigator .childNavigator-contentPlaceholder {
        max-width: 1400px;
    }
}

@media screen and (orientation: portrait) and (max-width: 500px) {
    .fragment header[role=banner] {
        -ms-grid-columns: auto 1fr;
        margin-left: 15px;
        margin-right: 15px;
    }

    .phone .fragment header[role=banner] {
        padding-left: 15px;
        padding-right: 15px;
        margin-left: 0;
        margin-right: 0;
    }

    .fragment header[role=banner] .win-backbutton {
        -ms-grid-column: 1;
        margin-bottom: 0;
        margin-left: 5px;
        margin-right: 5px;
        margin-top: 76px;
    }

    .fragment header[role=banner] .win-backbutton:disabled {
        display: none;
    }

    .fragment header[role=banner] .titlearea {
        margin-bottom: 0;
        margin-left: 5px;
        margin-right: 5px;
        margin-top: 68px;
    }
}

@media screen and (orientation: portrait) {
    .fragment {
        -ms-grid-rows: 100px 1fr;
    }

    .fragment header[role=banner] {
        -ms-grid-columns: 29px 71px 1fr auto;

        .win-backbutton {
            margin-top: 32px;
        }

        .titlearea {
            margin-top: 17px;
            font-size: 32pt;
        }

        .codelink {
            .text {
                display: none;
            }

            &.visible {
                opacity: 1;
            }
        }
    }

    .desc-screen {
        -ms-grid-rows: 5px auto 10px 1fr;
        -ms-grid-columns: 40px 1fr 40px;
        font-size: 12pt;

        .bloc-description {
            padding: 10px 20px;
            -ms-grid-row: 2;
            -ms-grid-column: 2;
        }

        .bloc-content {
            -ms-grid-row: 4;
            -ms-grid-column: 2;
        }
    }
}
